﻿@inject NavigationManager UriHelper

@code {
    [Parameter]
    public bool IsAuthenticated { get; set; }

    protected override void OnInitialized()
    {
        if (!IsAuthenticated)
        {
            UriHelper.NavigateTo("login", true);
        }
        else
        {
            UriHelper.NavigateTo("Unauthorized", true);
        }
    }
}